<template>
  <div>
      <order-header :title="title">
        <template #info>
          <span>{{info}}</span>
        </template>
      </order-header>
      <router-view></router-view>
      <service-bar></service-bar>
      <nav-footer></nav-footer>
  </div>
</template>

<script>
import OrderHeader from '../components/OrderHeader'
import ServiceBar from "../components/ServiceBar";
import NavFooter from '../components/NavFooter'
export default {
  name:'order',
  components:{
    OrderHeader,
    NavFooter,
    ServiceBar
  },
  data() {
    return {
      title:'',
      info:''
    }
  },
  mounted(){
    let path=this.$route.path
    if(path=='/order/confirm'){
      this.title='确认订单'
      this.info='请认真填写收货地址'
    }else if(path=='/order/list'){
      this.title='订单列表'
      this.info='请谨防钓鱼链接或诈骗电话，了解更多>'
    }else if(path=='order/pay'){
      this.title='订单支付'
      this.info='请谨防钓鱼链接或诈骗电话，了解更多>'
    }else if(path=='order/alipay'){
      this.title='订单支付'
      this.info='请谨防钓鱼链接或诈骗电话，了解更多>'
    }
  }
}
</script>

<style>

</style>